<template>
  <div>
    <router-view>
      <template v-slot="{ Component }">
        <transition :name="getTransitionName()">
          <component :is="Component"></component>
        </transition>
      </template>
    </router-view>
  </div>
</template>

<script>
import { defineComponent } from 'vue'
import { getTransitionName } from './transition'

export default defineComponent({
  name: 'RenderPage',
  setup() {
    return {
      getTransitionName
    }
  }
})
</script>
